package _spring_test._properties;

import java.util.ResourceBundle;

/**
 * @Author: huangya
 * @Date: 2020/5/18
 * @Description:
 */
public class Property2Test {

    public static void main(String[] args) {
        //注意：这个getBundle()方法的参数只能写成包路径+properties文件名（不能带.properties文件后缀），否则将抛异常
        ResourceBundle rb = ResourceBundle.getBundle("properties/test");
        String name = rb.getString("name");
        System.out.println(name);
    }
}
